package com.un.ebs.workflow.domain;

import java.util.Date;

import com.un.ebs.inventory.enums.InventoryTypeEnum;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.baomidou.mybatisplus.annotation.*;
import java.io.Serializable;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import org.springframework.stereotype.Component;
import lombok.Data;
import com.un.ebs.core.metadata.DbField;

/**
 * (WorkflowInstance)表实体类
 *
 * @author liubo
 * @since 2020-08-23 22:13:59
 */
@Data
@Component
@TableName("tb_workflow_instance")
@SuppressWarnings("serial")
public class WorkflowInstance extends Model<WorkflowInstance> {

    @TableId(value = "id", type = IdType.UUID)
    private String id;


    @DbField(name = "workflow_id", length = 40, precision = 0)
    private String workflowId;

    @DbField(name = "workflow_name", length = 100, precision = 0)
    private String workflowName;

    @TableField(fill = FieldFill.INSERT)
    @DbField(name = "create_time", length = -1, precision = 0)
    private Date createTime;

    @TableField(fill = FieldFill.INSERT)
    @DbField(name = "create_at", length = 40, precision = 0)
    private String createAt;

    @TableField(fill = FieldFill.INSERT)
    @DbField(name = "create_at_name", length = 100, precision = 0)
    private String createAtName;

    @DbField(name = "close_time", length = -1, precision = 0)
    private Date closeTime;

    @DbField(name = "close_status", length = -1, precision = 0)
    private Boolean closeStatus;

    @DbField(name = "remark", length = 500, precision = 0)
    private String remark;

    @DbField(name = "tenant_id", length = 40, precision = 0)
    private String tenantId;

    @DbField(name = "close_at", length = 40, precision = 0)
    private String closeAt;

    @DbField(name = "close_at_name", length = 100, precision = 0)
    private String closeAtName;

    @DbField(name = "close_remark", length = 500, precision = 0)
    private String closeRemark;

    @DbField(name = "pass_status", length = -1, precision = 0)
    private Boolean passStatus;

    @DbField(name = "inventory_type", length = -1, precision = 0)
    private InventoryTypeEnum inventoryType;

    @DbField(name = "inventory_note_id", length = 40, precision = 0)
    private String inventoryNoteId;

    @DbField(name = "inventory_note_code", length = 40, precision = 0)
    private String inventoryNoteCode;

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

}